#mapping-script
# -*- coding: ms949 -*-

from bots.botsconfig import *
from edifact import syntax
from recordsD94AUN import recorddefs


structure = [
{ID: 'UNH', MIN: 1, MAX: 1, LEVEL: [
    {ID: 'BGM', MIN: 1, MAX: 1},
    {ID: 'DTM', MIN: 0, MAX: 3},
    {ID: 'LOC', MIN: 0, MAX: 99},
    {ID: 'NAD', MIN: 0, MAX: 9},
    {ID: 'TDT', MIN: 0, MAX: 9, LEVEL: [
        {ID: 'LOC', MIN: 0, MAX: 9},
    ]},
    {ID: 'RFF', MIN: 0, MAX: 9999, LEVEL: [
        {ID: 'PAC', MIN: 0, MAX: 3},
        {ID: 'MEA', MIN: 0, MAX: 99},
        {ID: 'LOC', MIN: 0, MAX: 9},
        {ID: 'DOC', MIN: 0, MAX: 99, LEVEL: [
            {ID: 'DTM', MIN: 0, MAX: 3},
            {ID: 'MEA', MIN: 0, MAX: 5},
        ]},
        {ID: 'EQD', MIN: 0, MAX: 999, LEVEL: [
            {ID: 'EQN', MIN: 0, MAX: 9},
            {ID: 'MEA', MIN: 0, MAX: 9},
            {ID: 'SEL', MIN: 0, MAX: 9},
        ]},
        {ID: 'NAD', MIN: 0, MAX: 9, LEVEL: [
            {ID: 'CTA', MIN: 0, MAX: 5},
            {ID: 'COM', MIN: 0, MAX: 5},
        ]},
    ]},
    {ID: 'CNT', MIN: 0, MAX: 9},
    {ID: 'UNT', MIN: 1, MAX: 1},                                

]}
]
